export  = IdGenerator;

/**
 *
 * @author 
 *
 */
class IdGenerator {
    
    private idCounter:number = 0;
    
    
	public constructor() {
	}
	
	// 设置初始值i［新id从i＋1开始］
    public initId( first ) { 
        this.idCounter = first;
    }
    
    // 返回新id
    public newId():number{
        ++this.idCounter;
        return this.idCounter;
    }
    
    // 返回当前id
    public curId():number{
        return this.idCounter;
    }
//SJG_MARK_APPEND--------------------


}//SJG_MARK_END-------------------------